package cn.com.taurus.impl;

import cn.com.taurus.bean.ClientAccounts;
import cn.com.taurus.entity.Client;
import cn.com.taurus.mapper.ClientMapper;
import cn.com.taurus.service.ClientService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author yh
 * @createTime 2021-06-23 16:41:51:01:21
 * @remark 业务逻辑层
 * @version 1.0
 */
@Service
public class ClientImpl implements ClientService {
    @Autowired
    private ClientMapper clientMapper;

    @Override
    public int clientRegister(Client client) {
        return clientMapper.clientRegister(client);
    }

    @Override
    public Client login(Client client) {
        return clientMapper.login(client);
    }

    @Override
    public int insertClient(ClientAccounts client) {
        return clientMapper.insertClient(client);
    }

    @Override
    public Client selectClientById(Integer cid) {
        return clientMapper.selectClientById(cid);
    }

    @Override
    public int updateClientById(ClientAccounts client) {
        return clientMapper.updateClientById(client);
    }

    @Override
    public int deleteClientById(ClientAccounts clientAccounts) {
        return clientMapper.deleteClientById(clientAccounts);
    }

    @Override
    public Integer selectCIdBycAccount(String cAccount) {
        return clientMapper.selectCIdBycAccount(cAccount);
    }

    @Override
    public List<ClientAccounts> selectAllClientAccount() {
        return clientMapper.selectAllClientAccount();
    }

    @Override
    public List<ClientAccounts> findClientAccount(ClientAccounts clientAccounts){
        return clientMapper.findClientAccount(clientAccounts);
    }

    @Override
    public List<Client> selectOne() {
        return clientMapper.selectOne();
    }
}
